<div data-extend-template="layouts/partials/table.html">
  <span data-block="no-rows-message" translate>
    There are no Content Views that match the criteria.
  </span>

  <span data-block="no-search-results-message" translate>
    Your search returned zero Content Views.
  </span>

  <table data-block="table" class="table table-striped table-bordered">
    <thead>
      <tr bst-table-head>
        <th bst-table-column="name" sortable>{{ "Name" | translate }}</th>
        <th bst-table-column>{{ "Composite View" | translate }}</th>
        <th bst-table-column>{{ "Last Published" | translate }}</th>
        <th bst-table-column>{{ "Repositories" | translate }}</th>
      </tr>
    </thead>

    <tbody>
      <tr bst-table-row ng-repeat="contentView in table.rows">
        <td bst-table-cell>
          <a ui-sref="content-view.versions({contentViewId: contentView.id})">
            {{ contentView.name }}
          </a>
        </td>
        <td bst-table-cell>
          <span ng-show="contentView.composite" translate>Yes</span>
          <span ng-hide="contentView.composite" translate>No</span>
        </td>
        <td bst-table-cell><long-date-time date="contentView.last_published" /></td>
        <td bst-table-cell class="number-cell">{{ contentView.repositories.length || 0 }}</td>
      </tr>
    </tbody>
  </table>
</div>
